Skip to content

chore: block subscription, deactivate actors#2120

Merged
Mirko-von-Leipzig merged 5 commits into
nextfrom
santiagopittella-ntx-builder-block-sub-phase-1
May 25, 2026
Merged

chore: block subscription, deactivate actors#2120
Mirko-von-Leipzig merged 5 commits into
nextfrom
santiagopittella-ntx-builder-block-sub-phase-1

Conversation

@SantiagoPittella
Copy link
Copy Markdown
Collaborator

@SantiagoPittella SantiagoPittella commented May 22, 2026

This PR:

  • Removes the NtxBuilder proto api.
  • Refactors the Ntx Builder to use a BlockSubscription instead of a mempool one.
  • Temporary deactivates the actors.
  • Streams the blocks until sync and marks is_synced to true when reached, after that it cointinues fetching and updating the local tip.

Caution

This change halts the execution of network transactions

@SantiagoPittella SantiagoPittella force-pushed the santiagopittella-ntx-builder-block-sub-phase-1 branch from 4e84942 to 3e73be1 Compare May 22, 2026 18:28
@SantiagoPittella SantiagoPittella added the no changelog This PR does not require an entry in the `CHANGELOG.md` file label May 22, 2026
@SantiagoPittella SantiagoPittella force-pushed the santiagopittella-ntx-builder-block-sub-phase-1 branch from 3e73be1 to 46170b5 Compare May 22, 2026 18:33
@SantiagoPittella SantiagoPittella force-pushed the santiagopittella-ntx-builder-block-sub-phase-1 branch from 46170b5 to 8da5828 Compare May 22, 2026 18:44
@igamigo
Copy link
Copy Markdown
Collaborator

igamigo commented May 22, 2026

Would it make sense to build this on top of #2095 considering #2095 (review)?

Copy link
Copy Markdown
Collaborator

@Mirko-von-Leipzig Mirko-von-Leipzig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This lgtm, some minor comments. Ideally this would include the store -> rpc gRPC service change since the former may or may no longer exist when this merges.

Comment on lines +322 to +324
let block_from = stored_chain_state
.as_ref()
.map_or(BlockNumber::GENESIS, |(num, ..)| num.child());
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can simplify the logic if we separate out the "bootstrapping" such that we always have at least the genesis block in the database. Similar to how the current store is bootstrapped.

But we can do that in a follow-up.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment thread bin/ntx-builder/src/committed_block.rs
Comment thread bin/ntx-builder/src/builder.rs
Comment thread bin/ntx-builder/src/clients/rpc.rs
@Mirko-von-Leipzig
Copy link
Copy Markdown
Collaborator

Would it make sense to build this on top of #2095 considering #2095 (review)?

I've actually come to the conclusion that merging this one first may resolve a lot of the questions people have by virtue of removing the network account stuff.

@Mirko-von-Leipzig
Copy link
Copy Markdown
Collaborator

Mirko-von-Leipzig commented May 25, 2026

@SantiagoPittella I've made the following changes to unblock and move other PRs along,

  • Replace block-producer and store clients with RPC client (allows me to yank gRPC services)
  • Since tx submission now goes via RPC

@Mirko-von-Leipzig Mirko-von-Leipzig merged commit d96a547 into next May 25, 2026
21 checks passed
@Mirko-von-Leipzig Mirko-von-Leipzig deleted the santiagopittella-ntx-builder-block-sub-phase-1 branch May 25, 2026 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no changelog This PR does not require an entry in the `CHANGELOG.md` file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants